package com.ygj.employee.service.impl;

import com.base.common.persistent.dao.EmployeeMapper;
import com.base.common.persistent.model.Employee;
import com.ygj.employee.service.EmployeeService;
import org.springframework.stereotype.Service;

import javax.annotation.Resource;
import java.util.List;

@Service("employeeService")
public class EmployeeServiceImpl implements EmployeeService {

	@Resource
	private EmployeeMapper employeeMapper;
	
	@Override
	public int chooseDefaultCompounds(int employeeId, int compoundsId) {
		return employeeMapper.updateChooseDefaultCompounds(employeeId, compoundsId);
	}

	@Override
	public List<Employee> getEmployeesByDeptAndCompoundsId(int dept, int compoundsId) {
		return employeeMapper.queryEmployeesByDeptAndCompoundsId(dept, compoundsId);
	}

}
